package CPUNumber;

/**
 * @author DCSGO
 * @version 1.0
 */
public class CPUNumber {
    public static void main(String[] args) {
        Runtime runtime = Runtime.getRuntime();
        //              可获得的处理器
        int i = runtime.availableProcessors();
        System.out.println("当前电脑有：" + i + " 个CPU");
        //当前电脑有：8 个CPU
    }
}
